


export const arrayToHeavy = (arr,option) => {//根据id去重

    let obj = {};
    arr = arr.reduce((newArr, next) => {
    obj[next[option]] ? "" : (obj[next[option]] = true && newArr.push(next));
    return newArr;
    }, []);
    return arr;

}